Security News
RubyGems.org Adds New Maintainer Role
RubyGems.org has added a new "maintainer" role that allows for publishing new versions of gems. This new permission type is aimed at improving security for gem owners and the service overall.
@smithy/eventstream-codec
Advanced tools
[![NPM version](https://img.shields.io/npm/v/@smithy/eventstream-codec/latest.svg)](https://www.npmjs.com/package/@smithy/eventstream-codec) [![NPM downloads](https://img.shields.io/npm/dm/@smithy/eventstream-codec.svg)](https://www.npmjs.com/package/@smi
@smithy/eventstream-codec is an npm package designed to handle the encoding and decoding of event streams. It is part of the Smithy framework, which is used for building SDKs and other tools for AWS services. This package is particularly useful for working with AWS services that use event streams, such as AWS Transcribe or AWS Kinesis.
Encoding Event Streams
This feature allows you to encode an event stream into a binary format. The code sample demonstrates how to create an event and encode it using the EventStreamMarshaller.
const { EventStreamMarshaller } = require('@smithy/eventstream-codec');
const marshaller = new EventStreamMarshaller();
const event = { headers: {}, body: Buffer.from('example data') };
const encoded = marshaller.marshall(event);
console.log(encoded);
Decoding Event Streams
This feature allows you to decode a binary event stream back into its original format. The code sample shows how to decode an encoded event using the EventStreamMarshaller.
const { EventStreamMarshaller } = require('@smithy/eventstream-codec');
const marshaller = new EventStreamMarshaller();
const encoded = Buffer.from('example encoded data');
const event = marshaller.unmarshall(encoded);
console.log(event);
The event-stream package is a toolkit for working with streams in Node.js. It provides a variety of utilities for creating and manipulating streams, including event streams. While it offers broader functionality than @smithy/eventstream-codec, it does not specifically focus on AWS event streams.
FAQs
[![NPM version](https://img.shields.io/npm/v/@smithy/eventstream-codec/latest.svg)](https://www.npmjs.com/package/@smithy/eventstream-codec) [![NPM downloads](https://img.shields.io/npm/dm/@smithy/eventstream-codec.svg)](https://www.npmjs.com/package/@smi
The npm package @smithy/eventstream-codec receives a total of 3,751,441 weekly downloads. As such, @smithy/eventstream-codec popularity was classified as popular.
We found that @smithy/eventstream-codec demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 2 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
RubyGems.org has added a new "maintainer" role that allows for publishing new versions of gems. This new permission type is aimed at improving security for gem owners and the service overall.
Security News
Node.js will be enforcing stricter semver-major PR policies a month before major releases to enhance stability and ensure reliable release candidates.
Security News
Research
Socket's threat research team has detected five malicious npm packages targeting Roblox developers, deploying malware to steal credentials and personal data.